﻿using CommonEntity;
using Microsoft.AspNetCore.Components;
using Microsoft.AspNetCore.Mvc;
using NetCroe6WebAPITestOneBusiness;

namespace NetCroe6WebAPITestOne.Controllers
{
    [ApiController]
    [Microsoft.AspNetCore.Mvc.Route("HttpClinetExp")]
    [Produces("application/json")]
    public class HttpClinetExpController:ControllerBase
    {
        private WeatherForecastBusiness _weatherForecastBusiness;

        public HttpClinetExpController(WeatherForecastBusiness weatherForecastBusiness)
        {
            _weatherForecastBusiness = weatherForecastBusiness;
        }

        /// <summary>
        /// httpclient接口测试
        /// </summary>
        /// <returns></returns>
        [HttpGet("HttpClientTest")]
        public async Task<ViewModelBase> HttpClientGetTest(string url)
        {
            return await _weatherForecastBusiness.HttpClientTest(url, "");
        }
    }
}
